:root {
  --background-color: #2c3e50;
  --line-color: #667c8e;
  --border-color: #7591ad;

  --text-color: #34495e;
}

* {
  margin: 0;
  padding: 0;
}

html {
  font-size: 14px;
}

body {
  width: 100vw;
  height: 100vh;
  background-color: var(--background-color);
  display: flex;
  justify-content: center;
  align-items: center;
  flex-direction: column;
  font-family: Shijie;
}

.item {
  position: relative;
  width: 120px;
  height: 40px;
  display: flex;
  justify-content: center;
  align-items: center;
  /* background-color: cadetblue; */
}

.item .line {
  width: 120px;
  height: 3px;
  background-color: var(--line-color);
  animation: line_width_change 1s linear infinite; /*1s 与ls(字母)*/
}

@keyframes line_width_change {
  0%,
  100% {
    width: 100%;
  }
  50% {
    width: 0%;
  }
}

.item::before,
.item::after {
  position: absolute;
  content: "";
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background-color: yellow;
}

.item::before {
  background-color: salmon;
  left: -15px;
  animation: circle_move1 2s linear infinite;
  z-index: 100;
}

.item::after {
  background-color: seagreen;
  right: -15px;
  animation: circle_move2 2s linear infinite;
  z-index: 200;
}

@keyframes circle_move1 {
  0% {
    left: -15px;
    width: 30px;
    height: 30px;
    z-index: 100;
  }
  25% {
    width: 25px;
    height: 25px;
  }
  50% {
    left: 105px;
    width: 30px;
    height: 30px;
  }
  75% {
    width: 35px;
    height: 35px;
  }
  100% {
    left: -15px;
    width: 30px;
    height: 30px;
    z-index: 200;
  }
}

@keyframes circle_move2 {
  0% {
    right: -15px;
    width: 30px;
    height: 30px;
    z-index: 200;
  }
  25% {
    width: 35px;
    height: 35px;
  }
  50% {
    right: 105px;
    width: 30px;
    height: 30px;
  }
  75% {
    width: 25px;
    height: 25px;
  }
  100% {
    right: -15px;
    width: 30px;
    height: 30px;
    z-index: 100;
  }
}

.item:nth-child(1) .line,
.item:nth-child(1)::after,
.item:nth-child(1)::before {
  animation-delay: 0.1s;
}
.item:nth-child(2) .line,
.item:nth-child(2)::after,
.item:nth-child(2)::before {
  animation-delay: 0.2s;
}
.item:nth-child(3) .line,
.item:nth-child(3)::after,
.item:nth-child(3)::before {
  animation-delay: 0.3s;
}
.item:nth-child(4) .line,
.item:nth-child(4)::after,
.item:nth-child(4)::before {
  animation-delay: 0.4s;
}
.item:nth-child(5) .line,
.item:nth-child(5)::after,
.item:nth-child(5)::before {
  animation-delay: 0.5s;
}
.item:nth-child(6) .line,
.item:nth-child(6)::after,
.item:nth-child(6)::before {
  animation-delay: 0.6s;
}
.item:nth-child(7) .line,
.item:nth-child(7)::after,
.item:nth-child(7)::before {
  animation-delay: 0.7s;
}
.item:nth-child(8) .line,
.item:nth-child(8)::after,
.item:nth-child(8)::before {
  animation-delay: 0.8s;
}
.item:nth-child(9) .line,
.item:nth-child(9)::after,
.item:nth-child(9)::before {
  animation-delay: 0.9s;
}
.item:nth-child(10) .line,
.item:nth-child(10)::after,
.item:nth-child(10)::before {
  animation-delay: 1s;
}
.item:nth-child(11) .line,
.item:nth-child(11)::after,
.item:nth-child(11)::before {
  animation-delay: 1.1s;
}
.item:nth-child(12) .line,
.item:nth-child(12)::after,
.item:nth-child(12)::before {
  animation-delay: 1.2s;
}
.item:nth-child(13) .line,
.item:nth-child(13)::after,
.item:nth-child(13)::before {
  animation-delay: 1.3s;
}
.item:nth-child(14) .line,
.item:nth-child(14)::after,
.item:nth-child(14)::before {
  animation-delay: 1.4s;
}
.item:nth-child(15) .line,
.item:nth-child(15)::after,
.item:nth-child(15)::before {
  animation-delay: 1.5s;
}
